]> git.r.bdr.sh - rbdr/map/blame_incremental - Map/Presentation/Base Components/EvolutionPicker.swift
Update license URL
[rbdr/map] / Map / Presentation / Base Components / EvolutionPicker.swift
... / ...
CommitLineData
1import SwiftUI
2
3struct EvolutionPicker: View {
4
5 @Binding var selectedEvolution: StageType
6
7 var body: some View {
8 Picker("Evolution", selection: $selectedEvolution) {
9 ForEach(StageType.types) { stage in
10 Text(Stage.title(stage)).font(.theme.body).tag(stage).padding(4.0)
11 }
12 Divider()
13 ForEach(StageType.characteristics) { stage in
14 Text(Stage.title(stage)).font(.theme.body).tag(stage).padding(4.0).font(.theme.body)
15 }
16 Divider()
17 ForEach(StageType.properties) { stage in
18 Text(Stage.title(stage)).font(.theme.body).tag(stage).padding(4.0)
19 }
20 Divider()
21 ForEach(StageType.custom) { stage in
22 Text(Stage.title(stage)).font(.theme.body).tag(stage).padding(4.0)
23 }
24 }.font(.theme.body).padding(.horizontal, 8.0).padding(.vertical, 4.0)
25 }
26}
27
28#Preview {
29 let selectedEvolution: StageType = .behavior
30 EvolutionPicker(selectedEvolution: .constant(selectedEvolution))
31}